package com.example.smartgreenhouse.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.example.smartgreenhouse.entity.LightOperationLog;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;
import java.util.List;

@Mapper
public interface LightOperationLogMapper extends BaseMapper<LightOperationLog> {
    @Select("SELECT * FROM light_operation_log WHERE light_id = #{lightId} ORDER BY operator_time DESC")
    List<LightOperationLog> selectByLightId(Long lightId);
}